package cn.ztydata.teachingsystem.heaven.web.dto;

import cn.ztydata.teachingsystem.heaven.entity.KnowledgePoint;
import org.hibernate.validator.constraints.Length;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.Min;
import javax.validation.constraints.NotNull;
import java.sql.Date;
import java.util.List;

/**
 * 资源详细数据
 *
 * @author fanruiping
 * @since 2014-12-08
 */
public class ResourceInfoDto {
    private Long id;//资源编号
    @NotNull
    @Min(value = 1, message = "所属专业编号不合法")
    private Long majorId;//专业编号
    private String majorName;//专业名称
    @NotNull
    @Length(min = 1, max = 60, message = "名称长度应为1~60")
    private String name;//资源名称
    @Length(max = 60, message = "名称长度应为0~60")
    private String author;//作者
    private String suffix;//媒体类型
    @NotNull
    @Min(value = 1, message = "资源类型编号不合法")
    private Integer typeId;//类型编号
    private String typeName;//类型名称
    @Length(max = 100, message = "来源长度应为0~100")
    private String source;//来源
    private Long uploaderId;//上传者编号
    private Integer role; //上传者角色
    private String uploader;//上传者名称
    private String remark;//简介
    @NotNull
    @Range(min = 0, max = 1, message = "资源种类不合法")
    private Integer mold;//种类
    private Date date;//添加时间
    private Long size;//资源大小
    private String downUrl;//下载地址
    private String showUrl;//显示地址
    private String content;//内容
    private List<KnowledgePoint> tags;//关键字集合

    private Integer status;//审核状态
    private Integer converterStatus;

    private Integer reader = 0;//浏览量
    private Integer loader = 0;//下载数

    private String photo;//头像
    private Integer groupType; //群组类型（0非群组 1课程群组 2专业群组 3班级群组）
    private Long groupId; //群组id
    private Integer pushed; //是否推荐（0不推荐 1推荐）
    private Long lessonId; //课程ID
    private Integer best; //是否搜藏

    public Long getId(){
        return id;
    }

    public void setId(Long id){
        this.id = id;
    }

    public Long getMajorId() {
        return majorId;
    }

    public void setMajorId(Long majorId) {
        this.majorId = majorId;
    }

    public Integer getTypeId() {
        return typeId;
    }

    public void setTypeId(Integer typeId) {
        this.typeId = typeId;
    }

    public List<KnowledgePoint> getTags() {
        return tags;
    }

    public void setTags(List<KnowledgePoint> tags) {
        this.tags = tags;
    }

    public String getMajorName() {
        return majorName;
    }

    public void setMajorName(String majorName) {
        this.majorName = majorName;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getAuthor() {
        return author;
    }

    public void setAuthor(String author) {
        this.author = author;
    }

    public String getSuffix(){
        return suffix;
    }

    public void setSuffix(String suffix){
        this.suffix = suffix;
    }

    public String getTypeName() {
        return typeName;
    }

    public void setTypeName(String typeName) {
        this.typeName = typeName;
    }

    public String getSource() {
        return source;
    }

    public void setSource(String source) {
        this.source = source;
    }

    public Long getUploaderId() {
        return uploaderId;
    }

    public void setUploaderId(Long uploaderId) {
        this.uploaderId = uploaderId;
    }

    public String getUploader(){
        return uploader;
    }

    public void setUploader(String uploader){
        this.uploader = uploader;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public Integer getMold() {
        return mold;
    }

    public void setMold(Integer mold) {
        this.mold = mold;
    }

    public Date getDate() {
        return date;
    }

    public void setDate(Date date) {
        this.date = date;
    }

    public Long getSize() {
        return size;
    }

    public void setSize(Long size) {
        this.size = size;
    }

    public String getDownUrl() {
        return downUrl;
    }

    public void setDownUrl(String downUrl) {
        this.downUrl = downUrl;
    }

    public String getShowUrl() {
        return showUrl;
    }

    public void setShowUrl(String showUrl) {
        this.showUrl = showUrl;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public String getPhoto() {
        return photo;
    }

    public void setPhoto(String photo) {
        this.photo = photo;
    }

    public Integer getReader(){
        return reader;
    }

    public void setReader(Integer reader){
        this.reader = reader;
    }

    public Integer getLoader(){
        return loader;
    }

    public void setLoader(Integer loader){
        this.loader = loader;
    }

    public Integer getStatus(){
        return status;
    }

    public void setStatus(Integer status){
        this.status = status;
    }

    public Integer getConverterStatus(){
        return converterStatus;
    }

    public void setConverterStatus(Integer converterStatus){
        this.converterStatus = converterStatus;
    }


    public Integer getGroupType() {
        return groupType;
    }

    public void setGroupType(Integer groupType) {
        this.groupType = groupType;
    }

    public Long getGroupId() {
        return groupId;
    }

    public void setGroupId(Long groupId) {
        this.groupId = groupId;
    }

    public Integer getRole() {
        return role;
    }

    public void setRole(Integer role) {
        this.role = role;
    }

    public Long getLessonId() {
        return lessonId;
    }

    public void setLessonId(Long lessonId) {
        this.lessonId = lessonId;
    }

    public Integer getPushed() {
        return pushed;
    }

    public void setPushed(Integer pushed) {
        this.pushed = pushed;
    }

    public Integer getBest() {
        return best;
    }

    public void setBest(Integer best) {
        this.best = best;
    }
}
